PRNAME = "program.exe"
LIBBOOST = "C:/boost_1_44/lib"
LIBOPENCV = "C:/OpenCV2.2/lib"
INCOPENCV = "C:/OpenCV2.2/include/opencv"
INCOPENCV2 = "C:/OpenCV2.2/include/opencv2"
INCOPENCVI = "C:/OpenCV2.2/include"
OPENCV = -I $(INCOPENCVI) -I $(INCOPENCV) -I $(INCOPENCV2)
INCBOOST = "C:/boost_1_44"

CFLAGS = -Wall -O2
OUTDIR = "/Release/"

all: $(PRNAME)
$(PRNAME): getter.o detector.o main.o
	g++ $(CFLAGS) getter.o detector.o  main.o  -o $(PRNAME) -I $(LIBBOOST) -I $(LIBOPENCV)
main.o: main.cpp getter.h detector.h 
	g++ $(CFLAGS) -c main.cpp
getter.o: getter.cpp 
	g++ $(CFLAGS) -c getter.cpp  $(OPENCV) -I $(INCBOOST)
detector.o: detector.cpp
	g++ $(CFLAGS) -c detector.cpp $(OPENCV)
run: $(PRNAME)
	$(PRNAME)
#clean:
	#rm -f *.o *.h.gch *.out *.out


#all: $(PRNAME)
#$(PRNAME):  main.o getter.o 
#	g++ $(CFLAGS) main.o -o $(OUTDIR)$(PRNAME)
#main.o: main.cpp 
#	g++ $(CFLAGS) -c main.cpp -I $(INCBOOST) -I $(OPENCV) -D"UNICODE" -D"_UNICODE" -D"_CONSOLE"
#run: $(PRNAME)
#	$(PRNAME)
#clean:
	#rm -f *.o *.h.gch *.out